falloutequestriafandomcom-20200223-history
User blog:ArtisticMink/Side Stories - Changes
__FORCETOC__ I gave the Side Stories Page a little love. The changes are pretty heavy but i decided to work on the open heart instead of creating temporary pages, since that would have been a lot more work. Please leave your feedback here. Also, if you dont approve the changes, feel free to revert them. Changed Entries The following entries have changed: *MediaWiki:Common.js *Side Stories *Template:StoryTable *Template:StoryEntry If you want to undo the changes, you have to jump back to revision 17:59, March 20, 2014 on Side Stories, 18:52, May 5, 2012 for StoryTable and 19:05, May 5, 2012‎ for StoryEntry. Common.js does not necessarily need an undo. In Detail For people not interested in the details, there is a TL;DR at the bottom of the page. Here is an in-depth explanation about what has changed and why. The table as a whole is great, but as yamato11 created the templates back then, a few errors crept in which remained til now. I removed the nested table setup and cleaned the templates. The generated html is now a lot more clean and the visuals are slightly improved. Also a user may now sort every column as his heart desires. This was not working with the nested table setup. I also altered almost all of the names, removing the Fallout: Equestria - in front of every name. For the sake of readability and sorting. The links remain intact. I also added some data attributes to make sure the columns get sorted in the right way (i.e. proper date and word count sorting). I made the table collapsible, which means that the synopsis is now hidden by default. In my opinion, this makes the 90 to 100 entries far more readable. Users can expand the synopsis by clicking on the synopsis button right next to the title. This is made possible by giving the synopsis a unique class, this class currently reads like this: mw-customtoggle- . As you may already guess, special characters in the names are a problem. Currently, this characters get parsed out by MediaWikis #replace macro: . , : ' and whitespaces. Sadly, that only covers a small amount of things that could go wrong. Wikias replace macro is a little tideous, i try to improve that in the future. Okay, what else changed. I changed the spacing a little mot make room for the Synopsis button, cleaned up the documentation inside the markup and added a new table containing discontiniued/abandoned stories. I resorted the tables, they are still not completly consistent but slightly better. Also here comes the probably biggest change: The values for chapters, words and last date modified get replaced by data from fimfiction.net as long as the synopsis contains a link to fimfiction.net'. '''This is done by a lightweight plugin i added to MediaWiki:Common.js. I'll explain in the next section how it works. If it comes to side-stories, the data is loaded after opening the site. This takes up to two seconds for me. Maybe slightly longer on computers with bad internet connection. I'm note sure how well it works on older mobile phones, but i didnt found this to be very important. The values in the markup itself only get replaced, not deleted. In theory, we could fetch all information from fimfiction, but to be honest, i dont like it. It somehow sunverts the whole idea of an wiki. But on the other hoof, lets be honest, no one was ever going to update all those chapter and word counts. Let alone the dates. I may add a "dont use fimfic" switch in the future, but i didnt want to blew up the markup any further. The Fimfiction.net Plugin The code for the plugin lies inside the MediaWiki:Common.js. What does the plugin do? IIt is a simple chainable jquery plugin named 'fimfic'. It can be used to fetch informations from fimfiction by using the story id and a key. It utilizes the fimfiction api, fetching all information about a story and then finding the one you want by using the given key word. Here is an example of what you can fetch using this plugin:http://www.fimfiction.net/api/story.php?story=119190 http://www.fimfiction.net/api/story.php?story=119190 Where is it avaiable? The plugin is avaiable on every page. Can i use it? Sure. However, due to security reasons you have to edit one of the wikis javascript source files. Since in-line js via editor is not allowed. Here is a cheatsheet containing all important files: http://community.wikia.com/wiki/Help:JavaScript_and_CSS_Cheatsheet Examples Moved all examples over to jsFiddle. You can find the documented fiddle here: http://jsfiddle.net/2cG3j/10/ In The Long Run One-Shots need to be either reworked with this scheme or get integrated into the short stories table for the sake of consistency. I also plan a importer that reads the google docs compilation post and translates it in wiki text. But that's far in the future. Known Bugs *After sorting, the synopsis button does not work properly. - '''Fixed' *Some Story names cause Problems. - Fixed (mostly) *Some entries without fimfiction link in their synopsis still have their inconsistent date/chapter/word descriptions. - No fix: No ff link, no data. Needs manual cleanup. *The plugin fetches the wrong information during some page views. - FIxed TL;DR Cleaned up side stories. New table for abandoned stories. Some informations are fetched from fimfiction, theres also a plugin for this. Trivia Music consumed: *Rolled Gold - The very best of the Rolling Stones LP, *Ink Spots, The Unforgettable Ink Spots LP, *Henry Hall and the BBC Dance Orchestra LP, *This is Henry Hall LP, *Fillydelphia Radio. Category:Blog posts